package net.csdn.business.common.domain.mirror.pop;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import net.csdn.business.common.domain.vo.OrgInfoVo;
import net.csdn.business.common.domain.vo.UserVo;

import java.io.Serializable;
import java.util.List;

@Data
@AllArgsConstructor
@NoArgsConstructor
public class MyGithubDto {
    private String token;
    private String thirdUsername;
    private int totalCount = 0;
    private int importCount = 0;
    private int notImportCount = 0;
    private List<Repository> items;
    private UserVo userInfo;
    private List<OrgInfoVo> orgInfos;
    private int type = 0;

    private int thirdTotalPage;
    private List<Organization> organizations;
    private String orgMessage;

    @Data
    public static class Repository implements Serializable {
        private long id;
        private String full_name;
        private String name;
        private String description;
        private String html_url;
        private String web_url;
        private Integer forks_count;
        private Integer stargazers_count;
        private String created_at;
        private String updated_at;
        private Owner owner;
        private Namespace namespace;
    }

    @Data
    @AllArgsConstructor
    @NoArgsConstructor
    public static class Owner implements Serializable {
        private long id;
        private String login;
        private String type;
    }

    @Data
    @AllArgsConstructor
    @NoArgsConstructor
    public static class Namespace implements Serializable {
        private long id;
        private String path;
        private String type;
    }

    @Data
    @AllArgsConstructor
    @NoArgsConstructor
    public static class Organization implements Serializable {
        private long id;
        private String avatar_url;
        private String description;
        private String login;
        private String path;
        private String url;
        private String html_url;
        private String name;
    }
}